﻿Public Class frmOometroActual
    Private mstrValor As String
    Public ReadOnly Property Valor() As String
        Get
            Valor = mstrValor
        End Get
    End Property
    Private Sub frmOometroActual_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        txtOdometro.Clear()
        txtOdometro.Text = 0
        txtOdometro.SelectAll()
    End Sub

    Private Sub txtOdometro_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles txtOdometro.KeyPress
        If e.KeyChar = Chr(Keys.Enter) Then
            Dim strRetVal As Double = 0

            Try
                strRetVal = txtOdometro.Text

            Catch ex As Exception
                strRetVal = 0
            Finally
                mstrValor = strRetVal
            End Try

            Me.DialogResult = Windows.Forms.DialogResult.OK
        End If
    End Sub

    Private Sub txtOdometro_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtOdometro.TextChanged

    End Sub
End Class